<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">

<head>
  <meta charset="UTF-8">
  <title>日报查看</title>
  <meta name="renderer" content="webkit">
  <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
  <meta name="viewport"
        content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
  <base href="http://localhost:8888"/>
  <link rel="stylesheet" href="css/font.css">
  <link rel="stylesheet" href="css/weadmin.css">
  <style>
    .h2-page{
      display: flex;
      justify-content: space-between;
    }
  </style>
</head>

<body>
<div class="weadmin-body">
  <fieldset class="layui-elem-field layui-field-title">
    <legend>日报系统</legend>
  </fieldset>
  <div class="layui-collapse" lay-filter="list">
    <div th:if="${list == null || list.size() == 0}">
      <h2 style="color: red;">抱歉，当前没有日报哦~</h2>
    </div>
    <div class="layui-colla-item" th:each="item : ${list}">
      <h2 class="layui-colla-title h2-page">
        <span style="font-weight: bold">日报题目：《[[${item.dailyTitle}]]》</span>
        <span>作者：[[${item.writerName}]]</span>
        <span style="color: darkred">提交时间：[[${item.writeTime}]]</span>
      </h2>
      <div class="layui-colla-content">
        <p th:text="${item.content}"></p>
      </div>
    </div>
  </div>
</div>
<script src="lib/layui/layui.js" type="text/javascript"></script>
<script>
  layui.use(['element', 'layer'], function(){
    var element = layui.element;

    //监听折叠
    element.on('collapse(list)', function(data){
    });
  });
</script>
</body>

</html>